package com.zz.ecommerce.togatherDeclareMgr.custDeclarationUpload;

import com.zz.ecommerce.togatherDeclareMgr.custDeclarationUpload.service.GoodsModelService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.ui.ModelMap;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;

/**
 * <一句话功能描述>
 * <功能详细描述>
 *
 * @author STEVEN
 * @date 2015/10/22,17:44
 */
@Controller
@RequestMapping("/model")
public class GoodsModelController {


    @Autowired
    private GoodsModelService goodsModelService;

    @RequestMapping(value = "chooseModel", method = {RequestMethod.GET, RequestMethod.POST})
    public String chooseModel(String hsCodeZ,String codeSC,String thisVal,ModelMap modelMap) {
        modelMap.put("models", goodsModelService.getModelByHscode(hsCodeZ,codeSC));
        modelMap.put("hsCodeZ", hsCodeZ);
        modelMap.put("thisVal", thisVal);
        return "/togatherDeclareMgr/declareCustApply/cust/chooseModel";
    }
}
